/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package module7.exercise2;


/**
 *
 * @author trang
 */
public class Fish extends Animal {
    public String name;

    public Fish(int legs, String name) {
        super(0);
        this.name = name;
    }

    public String getName() {
        return name;
    }

    public void play() {
    }

    public void setName(String name) {
      //  this.name=name;
    }

    @Override
    public void walk() {
        super.walk();
        System.out.println("Fish can not walk because it has not legs");
    }

    @Override
    public void eat() {

    }






    }




